<template>
    <div class="per">
        <div class="meTop">
            <!-- <div class="headPhoto">
            <input id="uploadFile" type="file" style="display:none" @click="clickChangeFile" />
            <img
                id="uploadImg"
                :src="avatar?avatar:defaultImg"
                alt="我是一个上传时的默认图片"
                @click="clickChangeImg"
            />
            </div> -->
            <!-- <div class="usersetting">
                <p style="font-weight:550" v-show="show">昵称：{{userNickName}}</p>
                <button class="btn btn-primary" @click="$router.push({name:'login'})" v-show="!show">登录</button>
            </div>
            <div class="me_setting_right">
                <span class="iconfont icon-saoyisao" @click="systemUpdate"></span>
                <span class="iconfont icon-shezhi" @click="$router.push({name:'usersetting'})"></span>
                <span class="iconfont icon-wodexiaoxi" @click="systemUpdate"></span>
            </div> -->
        </div>
    </div>
</template>
<style scoped>

</style>
<script>
// export default {
//     data() {
//     return {
//     //   show: isLogin(),
//     //   userNickName: "你猜我叫啥",
//       avatar: "",
//       defaultImg: require("../assets/logo.png")
//     };
//   },
//     methods:{
//         clickChangeFile() {
//         $("#uploadFile").change(function(event) {
//             var formData = new FormData();
//             formData.append("file", event.currentTarget.files[0]);
//             let config = {
//             headers: { "Content-Type": "multipart/form-data" }
//             };
//             post(
//             "http://127.0.0.1:3000/api/v1/file_uploads",
//             formData,
//             config
//             ).then(res => {
//               let user = JSON.parse(localStorage.getItem("userSingle"));
//             let userMessage = JSON.parse(localStorage.getItem("userMessage"));
//             let userObj = userMessage.find(item => {
//                 return item.username == user.username;
//             });
//           userObj.headimg = "http://localhost:3000" + res.data.info;
//           localStorage.setItem("userMessage", JSON.stringify(userMessage));
//           $("#uploadImg").attr("src", "http://localhost:3000" + res.data.info);
//         });
//       });
//     }
//     }
// }
</script>